From 0ffad73a59d3c831dfab66d4d06f1ab25fce66f2 Mon Sep 17 00:00:00 2001
From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Date: Thu, 18 Jul 2019 22:58:07 +0200
Subject: [PATCH] Fix for binutils 2.23.1

libbfd from binutils 2.23.1+ requires PACKAGE* definitions from autoconf.
So include config.h now that dropwatch uses autoconf

Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
[Retrieved (and slightly updated) from:
https://git.buildroot.net/buildroot/tree/package/dropwatch/0001-binutils-2.23.1.patch]
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
[Retrieved from:
https://github.com/nhorman/dropwatch/commit/0ffad73a59d3c831dfab66d4d06f1ab25fce66f2]
---
 src/lookup.c     | 3 +++
 src/lookup_bfd.c | 2 ++
 src/lookup_kas.c | 2 ++
 3 files changed, 7 insertions(+)

diff --git a/src/lookup.c b/src/lookup.c
index ba54991..521e292 100644
--- a/src/lookup.c
+++ b/src/lookup.c
@@ -24,6 +24,9 @@
  * 1) /usr/lib/debug/<kernel version> using libbfd
  * 2) /proc/kallsyms
  */
+
+#include "config.h"
+
 #include <stdlib.h>
 #include <stdio.h>
 #include <sys/utsname.h>
diff --git a/src/lookup_bfd.c b/src/lookup_bfd.c
index cc7010b..2c08e5e 100644
--- a/src/lookup_bfd.c
+++ b/src/lookup_bfd.c
@@ -22,6 +22,8 @@
  * symbollic name using the bfd library
  */
 
+#include "config.h"
+
 #include <stdlib.h>
 #include <stdio.h>
 #include <sys/utsname.h>
diff --git a/src/lookup_kas.c b/src/lookup_kas.c
index 5e05630..2300220 100644
--- a/src/lookup_kas.c
+++ b/src/lookup_kas.c
@@ -22,6 +22,8 @@
  * symbolic name using /proc/kallsyms
  */
 
+#include "config.h"
+
 #include <stdlib.h>
 #include <stdio.h>
 #include <stdint.h>
